<?php
/*IMPORTANT: 注意检查文件字符集是否为UTF-8*/
require_once "./include/main.inc.php";
if(@$_GET['type'])
{
	$case = $_GET['type'];
	switch ($case)
	{
		case "serverhtml":
			echo AjaxHTMLServerProcess();
			break;
		case "zabbixEvents":
			echo json_encode(ZabbixFuncGetDashboard());
			break;
		case "zabbixEventsMonitor":
			if(@$_SERVER['HTTP_USER_AGENT']=="Kanbix HTTP Monitor")
			{
				echo "OK";
				$arr = ZabbixFuncGetDashboard();
				file_put_contents("./rss/zabbix_rss.json",json_encode($arr));
			}
			break;
		default:
			break;
	}
	exit();
}


?>